package com.qzy.demo.mapper;

import com.qzy.demo.pojo.UUserPojo;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.Results;
import org.apache.ibatis.annotations.Select;

public interface UUserMapper {

    @Select("SELECT * FROM u_user WHERE nickname = #{userName}")
    @Results({
            @Result(property = "id",  column = "id"),
            @Result(property = "nickname",  column = "nickname"),
            @Result(property = "email", column = "email"),
            @Result(property = "pswd", column = "pswd"),
            @Result(property = "createTime", column = "createTime"),
            @Result(property = "lastLoginTime", column = "lastLoginTime"),
            @Result(property = "status", column = "status"),
           // @Result(property = "roleStrlist", column = "roleStrlist"),
            //@Result(property = "perminsStrlist", column = "perminsStrlist"),
    })
    UUserPojo findByName(String userName);
}
